﻿<Page
    x:Class="MediaCaptureDemo.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:MediaCaptureDemo"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}" RequestedTheme="Light">
        <Grid Margin="120,10,0,0">
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto"/>
                <RowDefinition/>
            </Grid.RowDefinitions>
            <StackPanel Orientation="Horizontal">
                <Button Click="InitCamera_Click" Content="Initialize Camera" />
                <Button Click="StartCapturePreview_Click" Content="Start Capture Preview" />
                <Button Click="CapturePhoto_Click" Content="Capture Photo"/>
                <Button Click="StopCapturePreview_Click" Content="Stop Capture Preview" />
            </StackPanel>

        </Grid>
        <Image HorizontalAlignment="Left" Height="383" Margin="120,154,0,0" VerticalAlignment="Top" Width="729" Source="Assets/camera.jpg"/>
        <CaptureElement x:Name="capturePreview" VerticalAlignment="Top" HorizontalAlignment="Left" Margin="159,218,0,0" Width="341" Height="262" />
        <Image HorizontalAlignment="Left" Height="383" VerticalAlignment="Top" Width="487" Source="Assets/frame.jpg" Margin="701,154,0,0"/>
        <Image x:Name="imagePreview" Stretch="UniformToFill" Margin="765,218,0,0" VerticalAlignment="Top" HorizontalAlignment="Left" Height="248" Width="312" />

    </Grid>
</Page>
